/**
 * ���Ź��������
 */
Ext.define('AM.controller.deptController',{
	extend:'Ext.app.Controller',
	init:function(){
		this.control({
			'deptlist button[id=add]' : {
				click:function(button){
					var grid = button.ownerCt.ownerCt;
					var modelObj = {
						text:'',
						id:'01',
						info:'',
						orderIndex:0,
						manager:'',
						nodeType:'Root',
						leaf:true
					}
					Ext.create('AM.util.GridDoActionUtil').doInsert(grid,modelObj);
				}
			}
		})
	},
	views:['MainLayout','DeptList','DeptTree'],
	models:[],
	stores:['deptStore','DeptStore4Tree']
});